﻿/**
 * ...
 * @author alijaya
 */

package homponex.core;
import flash.text.TextField;
import flash.text.TextLineMetrics;

class Label extends Component
{

	private var _text : String;
	public var text(get_text,set_text) : String
	
	private function get_text() : String
	{
		return _text;
	}
	
	private function set_text(value:String) : String
	{
		_text = value;
		return value;
	}
	
	private var tf:TextField;
	
	public function new() 
	{
		super();
		tf = new TextField();
		sprite.addChild(tf);
		tf.selectable = false;
		var m:TextLineMetrics = tf.getLineMetrics(0);
		tf.height = m.height + 4;
	}
	
}